<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
</head>
<body>
  <script>


    let list=['c','w','a'];

    // 数组内置的方法排序  改变原数组
    list.sort();

    console.log(list);  

  </script>
</body>
</html>